package top.hekun.study.reptile.util;

import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;

import java.io.IOException;

/**
 * 爬虫工具
 * @Author: 贺坤
 * @Date: 2023/4/23 14:53
 */
public class JsoupUtil {
    /**
     * 根据url 获取页面
     * @param url
     * @return
     */
    public static Document getDocumentByUrl(String url) throws IOException {
        Document document = Jsoup.connect(url).get();
        return document;
    }
}
